<?php
	//include('../pub.php'); 
	//include(_ROOT.'/db.php');
	
	// 从数据库从选出 year,level,class,point 放在页面的上端供选择
	// width = 340
?>
		<td width = "40">年份:</td>
		<td width = "80">
			<select name="year">
					<?php
					$sql = "select * from t_year order by t_year desc";
					$data = mysql_query($sql, $conn);
					while ($arr = mysql_fetch_array($data))
					{
					?>
				<option value="<?php echo $arr['t_year'];?>"><?php echo $arr['t_year'];?></option>	
					<?php
					}
					mysql_free_result($data);
					?>
			</select>
		</td>
		<td width = "40">等级:</td>
		<td width = "60">
			<select name="level">
					<?php
					$sql = "select * from t_level order by t_level";
					$data = mysql_query($sql, $conn);
					while ($arr = mysql_fetch_array($data))
					{
					?>
				<option value="<?php echo $arr['t_level'];?>"><?php	echo $arr['t_level'];?>级</option>	
					<?php
					}
					mysql_free_result($data);
					?>
			</select>
		</td>
		<td width = "40">题型:</td>
		<td width = "80">
			<select name="class">
					<?php
					$sql = "select * from t_class order by t_class";
					$data = mysql_query($sql, $conn);
					while ($arr = mysql_fetch_array($data))
					{
					?>
				<option value="<?php echo $arr['t_class'];?>"><?php 
																if ($arr['t_class']=='1')
																	echo '单选题';
																else
																	echo '未定题型';
																?></option>	
					<?php
					}
					mysql_free_result($data);
					?>
			</select>
		</td>

